#include<stdio.h>
const int maxn=30;
float a[maxn][maxn],dp[maxn][maxn];
int main()
{
	float n=2086458231.0;
	for(int i=0;i<maxn;i++){
		for(int j=0;j<=i;j++){
			scanf("%f",&a[i][j]);
		}
	}
	dp[0][0]=a[0][0];
	for(int i=1;i<maxn;i++){
		dp[i][0]=a[i][0]+dp[i-1][0]/2;
		dp[i][i]=a[i][i]+dp[i-1][i-1]/2;
	}
	for(int i=1;i<maxn;i++){
		for(int j=1;j<=i;j++){
			dp[i][j]=dp[i-1][j-1]/2+dp[i-1][j]/2+a[i][j];
		}
	}
	for(int i=0;i<maxn;i++){
		for(int j=0;j<=i;j++){
			printf("%.10f ",dp[i][j]);
		}
		printf("\n");
	}
	double Max,Min,sum;
	Max=dp[maxn-1][0];
	Min=dp[maxn-1][0];
	for(int i=1;i<maxn;i++){
		if(dp[maxn-1][i]>Max){
			Max=dp[maxn-1][i];
		}
		if(dp[maxn-1][i]<Min){
			Min=dp[maxn-1][i];
		}
	}
	printf("%.10f\n%.10f\n",Max,Min);
	sum=Max/Min;
	printf("%.10f\n",sum);
	sum*=n;
	printf("%.10f\n",sum);
	return 0;
}
